In a cluster of virtual machine (VM) hosts, memory is allocated to a VM's address space based on user-configured memory allocation parameters, memory demands from the VM and available memory on the VM host. When a cluster manager places more VMs on a VM host to increase consolidation, the VMs on that host may receive a lesser share of memory, which increases memory pressure on the VM. When a VM host is under memory pressure, memory pages may be reclaimed from one VM and given to another VM having greater priority.
The VM's memory may be reclaimed using a variety of memory reclamation techniques. For example, memory may be reclaimed from VMs using transparent page sharing (TPS), memory compression, memory ballooning and hypervisor-level swapping of memory pages. Memory ballooning requires the active participation of the guest operating system (OS) inside the VM. A balloon driver resides inside the guest OS and reclaims memory pages. These memory reclamation techniques frequently result in decreased performance of one or more workloads running on the VM, depending on the amount of memory reclaimed by each method.